package com.atos.smp.business.impl;

import java.io.Serializable;
import java.util.List;

import com.atos.smp.beans.Collaborator;
import com.atos.smp.beans.Project;
import com.atos.smp.business.ProjectManager;
import com.atos.smp.dao.ProjectDao;

public class ProjectManagerImpl implements ProjectManager,Serializable {
	
	private ProjectDao dao;
	
	public ProjectManagerImpl(ProjectDao dao) {
		super();
		this.dao = dao;
	}

	public ProjectDao getDao() {
		return dao;
	}

	public void setDao(ProjectDao dao) {
		this.dao = dao;
	}

	@Override
	public void save(Project project) {
		dao.save(project);
	}

	@Override
	public void update(Project project) {
		dao.update(project);
	}

	@Override
	public void delete(Project project) {
		dao.delete(project);
	}

	@Override
	public Project findProjectById(int id) {
		return dao.findProjectById(id);
	}

	@Override
	public List<Project> findAll() {
		return dao.findAll();
	}

	@Override
	public List<Collaborator> findAllManagers() {
		return dao.findAllManagers();
	}
	@Override
	public List<Collaborator> findAllProjectManagers() {
		return dao.findAllProjectManagers();
	}


	@Override
	public List<Collaborator> findAllCollaborators() {
		return dao.findAllCollaborators();
	}

	@Override
	public List<Collaborator> findAllCollaboratorsNotInProject(int id) {
		return dao.findAllCollaboratorsNotInProject(id);
	}

	@Override
	public List<Project> findProjectsByDas(String das) {
		
		return dao.findProjectsByDas(das);
	}
	
}
